package www.xpu.edu.app.student;

import android.content.DialogInterface;
import android.support.v7.app.ActionBar;
import android.support.v7.app.AlertDialog;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;
import android.widget.Toast;

import www.xpu.edu.app.MainActivity;
import www.xpu.edu.app.R;

public class Activity_stu_19 extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_stu_19);
        ActionBar actionBar = getSupportActionBar();
        if (actionBar != null) {
            actionBar.hide();
        }
        /**
         *    我的优势
         *    求职期望
         *    实习经历
         *    项目经历
         *    教育经历
         *    社交主页-->
         */
        Button button_back=findViewById(R.id.title_back);
        button_back.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                finish();
            }
        });
        Button button_change=findViewById(R.id.title_change);
        button_change.setVisibility(View.INVISIBLE);
        TextView text=(TextView)findViewById(R.id.title_text);
        text.setText("简历管理");

        Button button1=findViewById(R.id.stu19_button1);
        Button button2=findViewById(R.id.stu19_button2);
        Button button3=findViewById(R.id.stu19_button3);
        Button button4=findViewById(R.id.stu19_button4);
        Button button5=findViewById(R.id.stu19_button5);
        Button button6=findViewById(R.id.stu19_button6);

        final TextView text1=findViewById(R.id.stu19_text1);
        final TextView text2=findViewById(R.id.stu19_text2);
        final  TextView text3=findViewById(R.id.stu19_text3);
        final TextView text4=findViewById(R.id.stu19_text4);
        final TextView text5=findViewById(R.id.stu19_text5);
        final TextView text6=findViewById(R.id.stu19_text6);
        button1.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                    AlertDialog.Builder builder=new AlertDialog.Builder(Activity_stu_19.this);
                builder.setTitle("编辑");
                //builder.setIcon(R.drawable.ic_launcher_background);
                final EditText edit=new EditText(Activity_stu_19.this);
                builder.setView(edit);
                builder.setPositiveButton("确定录入", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"录入成功",Toast.LENGTH_LONG).show();
                        text1.setText(edit.getText().toString().trim());
                    }
                });
                builder.setNegativeButton("取消", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"取消",Toast.LENGTH_LONG).show();
                    }
                });
                builder.create();
                builder.show();

            }
        });


        button2.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                AlertDialog.Builder builder=new AlertDialog.Builder(Activity_stu_19.this);
                builder.setTitle("编辑");
                //builder.setIcon(R.drawable.ic_launcher_background);
                final EditText edit=new EditText(Activity_stu_19.this);
                builder.setView(edit);
                builder.setPositiveButton("确定录入", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"录入成功",Toast.LENGTH_LONG).show();
                        text2.setText(edit.getText().toString().trim());
                    }
                });
                builder.setNegativeButton("取消", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"取消",Toast.LENGTH_LONG).show();
                    }
                });
                builder.create();
                builder.show();

            }
        });
        button3.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                AlertDialog.Builder builder=new AlertDialog.Builder(Activity_stu_19.this);
                builder.setTitle("编辑");
                //builder.setIcon(R.drawable.ic_launcher_background);
                final EditText edit=new EditText(Activity_stu_19.this);
                builder.setView(edit);
                builder.setPositiveButton("确定录入", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"录入成功",Toast.LENGTH_LONG).show();
                        text3.setText(edit.getText().toString().trim());
                    }
                });
                builder.setNegativeButton("取消", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"取消",Toast.LENGTH_LONG).show();
                    }
                });
                builder.create();
                builder.show();

            }
        });
        button4.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                AlertDialog.Builder builder=new AlertDialog.Builder(Activity_stu_19.this);
                builder.setTitle("编辑");
                //builder.setIcon(R.drawable.ic_launcher_background);
                final EditText edit=new EditText(Activity_stu_19.this);
                builder.setView(edit);
                builder.setPositiveButton("确定录入", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"录入成功",Toast.LENGTH_LONG).show();
                        text4.setText(edit.getText().toString().trim());
                    }
                });
                builder.setNegativeButton("取消", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"取消",Toast.LENGTH_LONG).show();
                    }
                });
                builder.create();
                builder.show();

            }
        });

        button5.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                AlertDialog.Builder builder=new AlertDialog.Builder(Activity_stu_19.this);
                builder.setTitle("编辑");
                //builder.setIcon(R.drawable.ic_launcher_background);
                final EditText edit=new EditText(Activity_stu_19.this);
                builder.setView(edit);
                builder.setPositiveButton("确定录入", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"录入成功",Toast.LENGTH_LONG).show();
                        text5.setText(edit.getText().toString().trim());
                    }
                });
                builder.setNegativeButton("取消", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"取消",Toast.LENGTH_LONG).show();
                    }
                });
                builder.create();
                builder.show();

            }
        });

        button6.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                AlertDialog.Builder builder=new AlertDialog.Builder(Activity_stu_19.this);
                builder.setTitle("编辑");
                //builder.setIcon(R.drawable.ic_launcher_background);
                final EditText edit=new EditText(Activity_stu_19.this);
                builder.setView(edit);
                builder.setPositiveButton("确定录入", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"录入成功",Toast.LENGTH_LONG).show();
                        text6.setText(edit.getText().toString().trim());
                    }
                });
                builder.setNegativeButton("取消", new DialogInterface.OnClickListener() {
                    @Override
                    public void onClick(DialogInterface dialog, int which) {
                        Toast.makeText(Activity_stu_19.this,"取消",Toast.LENGTH_LONG).show();
                    }
                });
                builder.create();
                builder.show();

            }
        });






    }
}
